#ifndef GLOBALVARIABLES_H
#define GLOBALVARIABLES_H

#include <QObject>
#include <QString>
#include <QQueue>
#include <QTcpSocket>
#include "globalvariables.h"


extern const QString ServerListenIp;

extern const QString isRelayTest;

extern const int ServerListenPort;

extern const QString RelayIp;

// EnvAvgTemperature 环境平均温度 TODO  动态获取的
extern const double EnvAvgTemperature;

extern const double HorizonMin;
extern const double HorizonMax;
extern const double VerticalMin;
extern const double VerticalMax;
extern const double DistanceOfMach;
extern const double DiameterOfBulletPx;

extern const double MaxAvailabilityRangeX;

extern const double MaxAvailabilityRangeY;

extern const double WeightOfTargetPaper;

extern const double HeightOfTargetPaper;

// MaximumWaitTime 最大等待时间
extern const int MaximumWaitTime;

//连接状态
//1表示未连接 2表示毁坏 3表示已连接 4表示校准中 5是就绪
extern const int Unconnected;
extern const int Breakdown;
extern const int CommonShooting;
extern const  int CalibrationTarget;
extern const int ToBeAssigned;

extern const QString  LengthOfWriteBackForTargetData;

extern const QString PrefixForWriteBack;

extern const QString rewriteTargetIdCommand;
extern const QString clearTargetCommand;
extern const QString lengthOfControlCommand;
extern const QString sequenceOfControlCommand;
extern const QString zeroHex;

//状态请求间隔ms
extern const int StateTime;

//电量请求间隔
extern const int VoltageTime;

//断开重连时间
extern const int ReconnectTime;

//移动速度
extern const int MoveSpeed;

//靶标数目
//extern const int TargetNumber;
const int TargetNumber=22;

const int beginstart = 0;

//标签缩小比例
extern const double TargetScaleBody;

//靶标大小
extern const int TargetSize;

//详细信息子弹大小
extern const int BulletSizeOne;

//靶标列表子弹大小
extern const int BulletSizeTwo;

extern const int BulletSizeThree;

//列表子弹数量
extern const int BulletNumber;

extern const double FilterNumber;

//按钮总数量
extern const int toolBarNumber;

//校准范围边界
extern const double LeftLimit;
extern const double RightLimit;
extern const double UpLimit;
extern const double DownLimit;

// 控制命令接口路由值 10000-19999

// RewriteTargetId 重写地址
extern const int RewriteTargetId;
// ClearTarget 清除靶标
extern const int 	ClearTarget;
// OpenCalibrationTargetById 开启校准
extern const int OpenCalibrationTargetById;
// CloseCalibrationTargetById 关闭校准
extern const int CloseCalibrationTargetById;
// OpenInfoEntry 打开信息录入
extern const int OpenInfoEntry;
// CloseInfoEntry 关闭信息录入
extern const int CloseInfoEntry;
// UserGrouping 配置分组
extern const int UserGrouping;
//绑定人员信息
extern const int    BindInfo;
//更改系统id  system_id
extern const int ChangeSystemId;

//二次校准
extern const int TwoCheck;

//发送日期
extern const int currentData;
//发送靶号和组号
extern const int addrAndGroupnumber;


extern const int upORdown;

//查找当前子弹数据
//extern const int SearchCurrentDate;



// 获取信息接口路由值 20000-29999
// GetTargetInfo 获取
extern const int    GetTargetInfo;
// GetTargetState 获取靶标状态
extern const int    GetTargetState;
// GetShowInfo 获取展示信息
extern const int    GetShowInfo;
// GetVoltage 获取电压
extern const int    GetVoltage;

extern const int GetTargetName;

//后端主动发送当前子弹信息
extern const int CurrentBullet;
//后端发送查找到的成绩信息
extern const int scoreBullet;

#endif // GLOBALVARIABLES_H
